package com.hmdp.controller;


import com.hmdp.model.dto.Result;
import com.hmdp.model.entity.BlogComments;
import com.hmdp.service.IBlogCommentsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;

import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;

import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author ghp
 * @since 2021-12-22
 */
@RestController
@RequestMapping("/blog-comments")
public class BlogCommentsController {

    @Autowired
    private IBlogCommentsService blogCommentsService;
    @PostMapping
    public Result saveBlog(@RequestBody BlogComments blogComments) {
        return blogCommentsService.giveComment(blogComments);
    }

}
